﻿using System;
using System.Collections.Generic;
using Magicodes.ExporterAndImporter.Core;
using Magicodes.ExporterAndImporter.Excel;
using NP.BPMReportPlatform.Entities.BPM_Business;
using OfficeOpenXml.Table;
using SqlSugar;

namespace NP.BPMReportPlatform.UserTrial.Dto
{
    [ExcelExporter(Name = "报表数据", TableStyle = TableStyles.Light10, AutoFitAllColumn = true)]
    public class GetCourseManageOutput
    {
        /// <summary>
        /// ID
        /// </summary>
        [IEIgnore]
        public string CourseId { get; set; }

        /// <summary>
        /// 课程编号
        /// </summary>
        [ExporterHeader(DisplayName = "课程编号")]
        public string CourseCode { get; set; }

        /// <summary>
        /// 课程名称
        /// </summary>
        [ExporterHeader(DisplayName = "课程名称")]
        public string CourseName { get; set; }

        /// <summary>
        /// 项目编号
        /// </summary>
        [IEIgnore]
        public string ProjectCode { get; set; }

        /// <summary>
        /// 项目名称
        /// </summary>
        [IEIgnore]
        public string ProjectName { get; set; }

        /// <summary>
        /// 状态
        /// </summary>
        [ExporterHeader(DisplayName = "所属项目")]
        public string Project
        {
            get
            {
                return this.ProjectName + "（" + this.ProjectCode + "）";
            }
        }

        /// <summary>
        /// 状态
        /// </summary>
        [IEIgnore]
        public int? Status { get; set; }

        /// <summary>
        /// 状态
        /// </summary>
        [ExporterHeader(DisplayName = "状态")]
        public string StatusName
        {
            get
            {
                return this.Status == 1 ? "生效" : "失效";
            }
        }
    }
}